package main

import (
	"fmt"
)

type Monkey struct{
	Name string 
}

type BirdAble interface{
	Flyint()
}
type FishAble interface{
	Swiming()
}

func (m Monkey)climbing(){
	fmt.Println(m.Name,"会爬树")
}

type LittleMoneky struct{
	Monkey //匿名继承
}

//实现BirdAble和FishAble接口的方法

func (m LittleMoneky)Flying(){
	fmt.Println(m.Name,"会飞")
}
func (m LittleMoneky)Swiming(){
	fmt.Println(m.Name,"会游泳")
}
func main(){


	monkey:=LittleMoneky{
		Monkey{
			Name:"悟空",
		},
	}

	monkey.climbing()
	monkey.Flying()
	monkey.Swiming()

	var msg [7]interface{}
	msg[0]=1
	msg[1]="china"
	msg[2]=11.2
	msg[3]='b'
	msg[4]=monkey 
	msg[5]="lucy"
	msg[6] = [...]int{1,2,3}

	fmt.Println(msg)
	type money struct{
		Name interface{}
		Address interface{}
	}
	var data = [...]interface{}{1,"test",112.3,money{"bbb",[...]float64{12.2}},"lucy",[...]string{"haha"},100}
	fmt.Println(data)

}